<?php
class Gallery extends AppModel {
	var $name = 'Gallery';
    var $validate = array(
        'title' => array(
            'minlength' => array(
                'rule'    => array('minLength', 1),
                'message' => 'Please enter title.'
            ),
            'maxlength' => array(
                'rule'    => array('maxLength', '100'),
                'message' => 'Title must be no larger than 100 characters long.'
            )
        ),
        'description' => array(
            'minlength' => array(
                'rule'    => array('minLength', 1),
                'message' => 'Please enter description.'
            )
        ),
        'author' => array(
            'minlength' => array(
                'rule'    => array('minLength', 1),
                'message' => 'Please enter your name.'
            )
        ),
        'email' => array(
            'minlength' => array(
                'rule'    => array('minLength', 1),
                'message' => 'Please enter your email.'
            ),
            'email' => array(
                'rule'    => array('email', true),
                'message' => 'Please supply a valid email address'
            )
        )
    );
} // Gallery

?>